import { isCodeMessage } from "../config"
import { ReportType } from "@/type/report"

/**
 * @author: 小佘佘🦀
 * @description: 添加Report
 * @param {ReportType} report
 * */
export const plusReport = async (report: ReportType) => {


    const response = await fetch(`/api-backend/api/team/plus`, {
        method: "POST",
        headers: {
            "content-type": "application/json;charset=utf-8",
        },
        body: JSON.stringify(report),
        redirect: "manual"
    })

    return isCodeMessage(response)
}